package com.hzit.loan.pay.controller;

import com.hzit.loan.pay.commonApi.req.RefundReq;
import com.hzit.loan.pay.service.IRefundService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.validation.Valid;

/**
 * 退款请求接口
 */
@RestController
@RequestMapping("/refund")
public class RefundController {

    @Autowired
    private IRefundService refundService;


    /**
     * 统一退款请求接口
     */
    @RequestMapping("/create")
    public void refund(@Valid @RequestBody RefundReq refundReq){

        refundService.doReund(refundReq);


    }


}
